1. Field of the Invention
The present invention relates to the correction of errors in position encoders used in servo systems.
2. Art Background
Servo systems are commonly used to control the position or movement of one object in relation to another. A typical servo loop drives a motor to position a mechanism in response to an input xe2x80x9ctargetxe2x80x9d position. Typical servo loops use a compensator such as a simple PID (Proportional, Integral, Derivative) or other more advanced compensators, to provide stable, predictable response.
In such a system, the encoder provides the only means by which the loop measures position and from which it is possible to calculate derivatives of position, such as velocity and acceleration. It is also possible to calculate integrals of position. Because of nonlinearities and other errors in the encoder, the indicated position of the mechanism may deviate from its actual position. The xe2x80x9cactualxe2x80x9d position is unknowable to the servo in such a system; only the xe2x80x9cindicatedxe2x80x9d position is known. Therefore, errors in the encoder affect the overall accuracy obtainable by the servo loop, and the performance of the system in which it is embedded.
The servo loop corrects for indicated position errors, as long as they occur at frequencies which are within the frequency response of the loop. As is known in the art, the loop response, in both amplitude and phase versus frequency, controls the stability of the loop. Modern control systems operate mostly in the digital domain, sampling the state of the system and generating motor control signals. In a perfect position encoder, the xe2x80x9cactualxe2x80x9d position would match the indicated position. However, due to imperfections in the position encoder, an indicated position may exhibit an offset (error) from the actual position. When intending to move at a velocity slow enough for the servo system to track the encoder errors, velocity errors will occur as the encoder imperfections are encountered.
Past systems made use of external references to detect encoder errors. What is needed is a way to correct for errors and nonlinearities in the encoder in a servo system, without using external references.
Encoder errors in a servo loop are modeled as disturbances having an amplitude and spectral distribution related to the structure of the encoder. These encoder errors are sampled by deliberately driving the system on a predetermined trajectory such that the dominant frequency components of the encoder errors fall outside the frequency response of the servo loop. The sampled encoder data is filtered to produce correction data. A first method of filtering employs a high pass filter. A second method of filtering first removes the predetermined trajectory from the sampled data, and then applies a high pass filter.